package com.yanqu.road.entity.activity.mammonhall;

import com.yanqu.road.entity.DataObject;
import com.yanqu.road.entity.FieldTypeAnnotation;

import java.util.HashMap;
import java.util.Map;

@FieldTypeAnnotation(tableName = "t_u_activity_mammon_hall_user")
public class MammonHallUserData extends DataObject {

    @FieldTypeAnnotation(select = true, update = true, desc = "玩家id")
    private long userId;

    @FieldTypeAnnotation(select = true, update = true, desc = "活动id")
    private int activityId;

    @FieldTypeAnnotation(desc = "膜拜详情")
    private Map<Integer, MammonHallWorship> worshipMap = new HashMap<>();

    @FieldTypeAnnotation(desc = "重置时间")
    private long resetTime;

    public long getUserId() {
        return userId;
    }

    public void setUserId(long userId) {
        if(this.userId != userId) {
            this.userId = userId;
            setUpdateOption();
        }
    }

    public Map<Integer, MammonHallWorship> getWorshipMap() {
        return worshipMap;
    }

    public void setWorshipMap(Map<Integer, MammonHallWorship> worshipMap) {
        if(this.worshipMap != worshipMap) {
            this.worshipMap = worshipMap;
            setUpdateOption();
        }
    }

    public long getResetTime() {
        return resetTime;
    }

    public void setResetTime(long resetTime) {
        if(this.resetTime != resetTime) {
            this.resetTime = resetTime;
            setUpdateOption();
        }
    }

    public int getActivityId() {
        return activityId;
    }

    public void setActivityId(int activityId) {
        if(this.activityId != activityId) {
            this.activityId = activityId;
            setUpdateOption();
        }
    }
}
